// This file is the test of step4_Hello.c
// If this file runs correctly,
// Then step4_Hello.c would run correctly
jmp main;

// Func: putc
putc:
  load (%bp), %ra;
  out %ra, 1;
  ret;

// func: puts
puts:
  rrmov %sp, %bp;
  call putc;
  ret;

// Func: main
main:
  push string;
  push %bp;
  rrmov %sp, %bp;
  call puts;
  halt;

string:
  irmov string, %dx;
  irmov 'H', %ra;
  store %ra, 0(%dx);
  irmov 'e', %ra;
  store %ra, 1(%dx);
  irmov 'l', %ra;
  store %ra, 2(%dx);
  irmov 'l', %ra;
  store %ra, 3(%dx);
  irmov 'o', %ra;
  store %ra, 4(%dx);
  irmov 0, %ra;
  store %ra, 5(%dx);
  
  
